As used in this specification, the term "computing system" includes a CPU with main storage, input/output channel control units, direct access storage devices, and other I/O devices coupled thereto such as is described in G. M. Amdahl, et al., U.S. Pat. No. 3,400,371, issued Sept. 3, 1968 and entitled, "Data Processing System". An "operating system" consists of a set of supervisory routines for controlling the operating of a computing system, including one or more of the following major functions: task management, storage management, input/output management, and data management. An "application program" is a program written to do a user's work, usually in a high-level language, and is loade into main storage and executed under the supervision of the operating system's task manager. A "data set" is any group of related data that one or more users may wish to access. A "record" is a subset of a data set containing all information relating to one element of related data that comprises a data set. A "pointer" is a register, main storage location, or portion of a data set record which contains the main storage or auxiliary storage address of a data item. An example of a pointer is the relative byte address (RBA) of a control interval (CI). A "key" is a register, main storage location, or portion of a data set record which provides an identifier (which may be unique) of the record. A "volume" is a certain portion of data, together with its data carrier (such as a drum, a disk pack, or part of a disk storage module) that can be conveniently handled as a unit. "Open" means to prepare a data set or file for processing; this is done by establishing control blocks in main storage describing the data set and controlling access thereto.
Data management performs the function of controlling the acquisition, analysis, storage, retrieval, and distribution of data. In so doing, it must control all operations associated with input/output devices, such as: allocating space on volumes, channel scheduling, storing, naming, and cataloging data sets, moving data between real and auxiliary storage, and handling errors that occur during input/output operations. The data management routines include access methods, catalog management, direct access device space management (DADSM), and open/close/end-of-volume support. Inasmuch as the method of this invention, in its operation of a computing system, relates to certain portions of these routines, they will be more fully described. Reference is made to IBM System/370 System Summary, IBM Publication Number GA 22-7001-6 (Dec. 1976), and IBM System/360 Operating System Introduction, IBM Publication Number GC 22-6534.
Access methods operate the computing system to move information between virtual storage and external storage, and maintain it in external storage. A variety of techniques and data set organizations are known in the prior art for gaining access to a data set.
A variety of data set organizations may be employed, including the following: sequential, partitioned, indexed sequential, and direct. Basic access methods, which can be used with each of the above data set organizations, include the following: basic sequential (BSAM), basic direct (BDAM), basic indexed sequential (BISAM), and basic partitioned (BPAM). Queued access methods, which can be used only with sequential and indexed sequential data set organizations, are the queued sequential (QSAM) and queued indexed sequential (QISAM).
BSAM sequentially organizes data and stores or retrieves physical blocks of data. PA1 BDAM organizes records within a data set on direct access volumes in any manner the pro grammer selects. Storage or retrieval of a record is set by actual or relative address within the data set. This address can be that of the desired record, or a starting point within the data set, where a search for the record based on a key furnished by a programmer begins. BDAM also uses addresses as starting points for searching for available space for new records. PA1 BISAM stores and retrieves records randomly from an indexed sequential data set. It reads selectively by using the READ macro instruction and specifying the key of the logical record to be retrieved. Individual records can be replaced or added randomly. PA1 BPAM, when used in conjunction with BSAM, stores and retrieves discrete sequences of data (members) belonging to the same data set on a direct access device. Each member has a simple name with the address where the sequence begins. Members can be added to a partitioned data set as long as space is available. (BPAM is usually used to store or retrieve programs). PA1 QSAM organizes data sequentially. It retrieves and stores logical records as requested. QSAM anticipates the need for records based on their sequential order, and normally has the desired record in virtual storage, ready for use before the request for retrieval. When writing data to external storage, the program normally continues as if the record has been written immediately although QSAM's routines may block it with other logical records, and defer the actual writing until the output buffer has been filled. PA1 QISAM creates an indexed sequential data set and retrieves and updates records sequentially from such a data set. Synchronization of the program with the completion of I/O transfer and record blocking/deblocking are automatic. QISAM can also reorganize an existing data set. PA1 Open a data control block (DCB) or access method control block (ACB) before a data is read or written. PA1 Close a data control block or access method control block after a data set has been read or written. PA1 Process end-of-volume (EOV) conditions when an end-of-volume or end-of-data (EOD) set condition occurs during an I/O operation. PA1 Verifies the mounting of volumes. PA1 Merges data set attributes from the data definition (DD) statement, VTOC or catalog into the control blocks. PA1 Determines access method routines. PA1 Processes input and output labels. PA1 Updates data set attributes and statistics in the catalog. PA1 Disposes of volumes. PA1 Frees control blocks. PA1 Restores the DCB or ACB to its original pre-open condition.
The virtual storage access method (VSAM) employs a modified basic and queued access technique and applies to both direct and sequential data sets. VSAM is used with direct access storage devices on the IBM System/370 VS1, SVS and MVS operating systems. It creates and maintains two types of data sets. One is sequenced by a key field within each record and is called a key-sequenced data set (KSDS). Data records are located by using the key field and an index that records key fields and the address of the associated data, similar to ISAM. The other is sequenced by the time of arrival of each record into the data set and is called an entry-sequenced data set (ESDS). Data records are located by using the record's displacement from the beginning of the data set. The displacement is called the RBA (relative byte address). The RBA is similar to the relative block address used with BDAM.
DADSM consists of routines that allocate space on direct access volumes to data sets. The routines are used primarily by job management routines during the initiation of job steps when space is obtained for output data sets. They are also used by other data management routines for increasing the space already assigned to a data set, and for releasing space no longer needed.
When space is needed on a volume, the DADSM routines check the volume table of contents (VTOC) for enough available contiguous tracks to satisfy the request. If there are not enough contiguous tracks, the request is filled using noncontiguous groups of free tracks.
Open/close/end-of-volume (O/C/EOV) support routines;
Open Processing: Before accessing a data set, an OPEN macro instruction must open the DCB (data control block) or ACB (access method control block) for that data set. When a processing program issues an OPEN macro instruction, the open routine of the control program:
Close Processing: After processing has been completed for a data set, a CLOSE macro instruction must close the DCB or ACB for that data set. When a processing program issues a CLOSE macro instruction, the close routine of the control program:
End-of-Volume Processing: EOV processing is performed when end-of-data set or end-of-volume conditions occur during I/O operations on sequentially organized data sets. When a routine of a sequential access method encounters a tape or file mark (end-of-data set) or an end-of-volume condition, the routine issues a supervisor call instruction to pass control to the EOV routine.
Catalog management routines maintain the collection of data set indexes (the catalog) that is used by the control program to locate volumes. The catalog management routines also locate the cataloged data sets. The catalog, itself a data set, resides on one or more direct access volumes. It contains indexes that relate data set names to the serial nubers and device types of the volumes containing the data sets. In maintaining the catalog, the catalog management routines create and delete indexes, and add or remove entries.
Prior art catalog management routines include the IBM OS Catalog (see OS/VS2 System Program Library, Data Management, IBM Publication No. GC 26-3830-1) and the IBM VSAM Catalog (see VSAM Primer and Reference, IBM Publication No. G820-5774-0.)
The OS Catalog contains indexes that relate data set names to the serial numbers and device types of the volumes containing the data sets. A volume table of contents (VTOC) resides on each volume, which contains the data set characteristics of the data sets residing on the volume. To open a data set, catalog management routines search through the OS catalog for the name of the data set. The catalog entry for that data set name includes the volume serial number. In order to access a data set on a volume, it is necessary to sequentially search the VTOC for the record containing the data set name, which record will include direct pointers to the start and end of all segments of the user data set. The user data set can then be read from the external device into main or virtual storage, where it will be available to the application program. The serial scan of the VTOC is a seriously time-consuming process, which increases in severity as hardware advances continue to increase the capacity of DASD devices.
One approach to avoiding the VTOC scan required in the operation of the OS catalog is implemented in the prior art VSAM catalog. The VSAM catalog includes, for each data set, not only the volume serial number of the volume containing the data set, but data set extent and other characteristics. Thus, from information in a central VSAM catalog, access is made directly to data sets on different volumes without the necessity of searching the VTOC of those different volumes. This catalog structure, while enabling the opening of a data set without the VTOC scan, introduced severe operational limitations, among which are catalog/data volume synchronization failure and volume ownership problems. The prior art VSAM catalog, with the catalog and the data sets residing on different volumes and with the data set characteristics stored in the catalog, requires that synchronization be maintained between catalog entries and the data sets (for example, the catalog record must contain correct extent information to reflect the location of the associated data set). This prevents a user from being able to restore a data volume or catalog from a back-up copy since to do so would most likely introduce out-of-synch conditions. Hence, more complex time consuming recovery procedures must be adopted by the user when error conditions in the catalog or data sets occur.
In order to detect this synchronization problem, the prior art VSAM catalog requires that only a single VSAM catalog can manage or reference data sets on any given volume, and a single volume cannot incude more than one VSAM catalog. These restrictions impose severe usability problems in many multiprocessing or multiprogramming system installations where a plurality of VSAM catalogs are required by different users. For instance, it would be highly advantageous to permit users to share volumes for both catalogs and data sets.